<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }
        
        .nav {
            width: 800px;
            height: 35px;
            margin: 100px auto;
        }
        
        .left,
        .center,
        .right {
            float: left;
            height: 35px;
            line-height: 35px;
        }
        
        .left {
            width: 10px;
            background: palegreen;
            margin-left: 10px;
        }
        
        .center {
            background: skyblue;
        }
        
        .right {
            width: 30px;
            margin-right: 30px;
            background: palegoldenrod;
        }
    </style>
</head>

<body>
    <!-- 滑动门导航：两侧固定，中间自适应（两侧大小固定，中间是自适应的）
    核心思想：三个盒子，左中右，分别有三个
    -->
    <div class="nav">
        <div class="left"></div>
        <div class="center">首页</div>
        <div class="right"></div>
    </div>
</body>

</html>